import { http } from "@/utils"

export const getChannelsApi = () => {
  return http.get('/channels')
}

export const createArticlesApi = (data) => {
  return http.post('/mp/articles?draft=false', data)
}

export const uploadArticlesApi = (data) => {
  return http({
    url: `/mp/articles/${data.id}?draft=false`,
    method: 'put',
    data 
  })
}